package com.lcx.db137.common;

import lombok.Data;

import java.util.HashMap;
import java.util.Map;

/**
 * @author lcx
 * @version 1.0
 * @Description 统一接口
 * @date 2024/12/25 9:29
 */
@Data
public class R {
    private Integer code=200;
    private String message ="成功";
    private Map<String,Object> data=new HashMap<>();
    public R add(String key,Object value){
        data.put(key,value);
        return this;
    }
    public R setCode(Integer code){
        this.code=code;
        return this;
    }
    public R setMessage(String message){
        this.message=message;
        return this;
    }
}
